package com.itheima.Thread09;

public class Demo {
    public static void main(String[] args) {
        //创建参数
        MyThread mt = new MyThread();
        //创建3个线程,用的同一个参数
        Thread th1 = new Thread(mt);
        Thread th2 = new Thread(mt);
        Thread th3 = new Thread(mt);
        //修改线程的名字
        th1.setName("窗口一");
        th2.setName("窗口二");
        th3.setName("窗口三");
        //开启线程
        th1.start();
        th2.start();
        th3.start();
    }
}
